Although in the correct spirit, it seems there is some other
dependency in the code that assumes ExtInts are queued until
thay can be immediately delivered (EFLAGS.IF==1). This patch
therefore caused instability in Linux guests.
Signed-off-by: Keir Fraser <keir@xensource.com>
int intr_type = APIC_DM_EXTINT;
int intr_vector = -1;
int re_injecting = 0;
+ unsigned long rflags;
ASSERT(vmcb);
re_injecting = 1;
}
+ /* Guest's interrputs masked? */
+ rflags = vmcb->rflags;
+ if (irq_masked(rflags)) {
+ HVM_DBG_LOG(DBG_LEVEL_1, "Guest IRQs masked: rflags: %lx", rflags);
+ /* bail out, we won't be injecting an interrupt this time */
+ return;
+ }
+
/* Previous interrupt still pending? */
if (vmcb->vintr.fields.irq) {
// printk("Re-injecting IRQ from Vintr\n");